package com.app.oral.service

import com.app.oral.model.User

interface UserService {
    fun getOrCreateUser(openid: String, nickname: String = "", avatarUrl: String = ""): User
    fun completeProfile(userId: Long, realName: String, gender: String, userType: String, classIds: List<Long>): Boolean
    fun completeProfile(userId: Long, realName: String, gender: String, userType: String, classId: Long?): Boolean // 兼容方法
    fun approveUser(userId: Long): Boolean
    fun rejectUser(userId: Long): Boolean
    fun getPendingUsers(): Map<String, List<User>>
    fun getAllUsers(): List<User>
    fun searchUsersByRealName(realName: String): List<User>
    fun getUsersByStatus(status: String): List<User>
    fun updateLastLoginTime(openid: String): Boolean
    fun getUserById(id: Long): User?
    fun getUsersByClassId(classId: Long): List<User>
    fun getUsersByType(userType: String): List<User>
    fun deleteUser(userId: Long): Boolean
}